package com.bolang.onlycode.demo.question;



import org.apache.catalina.LifecycleListener;

import java.util.List;
import java.util.concurrent.CopyOnWriteArrayList;

public abstract class Father {
    private final List<Integer> lifecycleListeners = new CopyOnWriteArrayList<>();
    public void addLifecycleListener(Integer i){
        lifecycleListeners.add(i);
    }
    public Integer[] findLifecycleListeners() {
        return lifecycleListeners.toArray(new Integer[0]);
    }

}
